See matches instantly as you type
Enter a regular expression, flags and some test text, and matches are highlighted as you type, with the total count and a list of each match's position and capture group values. Use it to build patterns for checking email or phone number formats, refine an expression that pulls lines out of a log, or see what someone else's regex actually catches.
The pattern runs as is on the JavaScript regular expression engine built into your browser. Any change to the pattern, flags or text reruns it immediately, and a syntax error turns the input red and shows the engine's error message. With the g flag on, every match to the end of the text is found; with it off, only the first. Zero-length matches (for example a pattern of just ^ or \b) are counted by stepping forward one position, so there is no infinite loop. For example, the pattern (\d{3})-(\d{4}) on '010-1234-5678' yields one match, '010-1234', with groups "010" and "1234". Characters already consumed are not reused, so '234-5678' is not matched separately. The list shows up to the first 50 matches with number, start index (counting from 0), matched string and group values. Everything runs in your browser.
\w covers only ASCII letters, digits and underscore. Use a code point range such as [\uAC00-\uD7A3] for Korean syllables, or turn on the u flag and use \p{L} to match a letter in any script.
A perfect email regex is extremely long. Usually [^\s@]+@[^\s@]+\.[^\s@]+ checks the shape, and a verification email confirms the address exists.
Regex engines differ slightly. This tool follows JavaScript, so lookbehind, named group syntax and Unicode handling can differ from Python, Java and others.
No. The pattern runs only in your browser and the page has no code that sends your input anywhere. It disappears when you close the page.